/*
 * Copyright (c) 2008 Benoit Bouchez, Nicolas Giard
 * 
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 * 
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 * 
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
 * SOFTWARE.
 */
package com.noocodecommit.wicket.stuff.jquery.plugin.ui.datepicker;

import com.noocodecommit.wicket.stuff.jquery.plugin.JQPluginOptions;
import com.noocodecommit.wicket.stuff.jquery.plugin.effects.JQAnimation;

/**
 * JQDatepicker Option set
 * 
 * @author Benoit Bouchez
 * 
 */
public class JQDatePickerOptions extends JQPluginOptions implements Cloneable
{
	/** show on focus value */
	public static String SHOWON_FOCUS = "focus";
	/** show on button value */
	public static String SHOWON_BUTTON = "button";
	/** show on both focus & button value */
	public static String SHOWON_BOTH = "both";

	private String clearText = "Clear";
	private String closeText = "Close";
	private String prevText = "<Prev";
	private String nextText = "Next>";
	private String currentText = "Today";

	private String clearStatus = "Erase the current date";
	private String closeStatus = "Close without change";
	private String prevStatus = "Show the previous month";
	private String nextStatus = "Show the next month";
	private String currentStatus = "Show the current month";
	private String monthStatus = "Show a different month";
	private String yearStatus = "Show a different year";
	private String weekStatus = "Week of the year";
	private String dayStatus = "Set DD as first week day";
	private String initStatus = "Select a date";
	private String dateStatus = "Select DD, M d";

	private String dayNames = "['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday']";
	private String dayNamesShort = "['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat']";
	private String dayNamesMin = "['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa']";
	private String monthNames = "['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December']";
	private String monthNamesShort = "['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec']";

	private String yearRange = "-10:+10";
	private String weekHeader = "Wk";
	private String rangeSeparator = " - ";
	private String defaultDate = ""; // Date(yyyy, mm - 1, dd), Number, String Default: null
	private String minDate = ""; // Date(yyyy, mm - 1, dd), Number, String Default: null
	private String maxDate = ""; // Date(yyyy, mm - 1, dd), Number, String Default: null
	private String shortYearCutoff = "+10";
	private String appendText = "";
	private String showOn = SHOWON_FOCUS;
	private String showAnim = JQAnimation.ANIMATIONMODE_SHOW;
	private JQPluginOptions showOptions;
	private String buttonText = "...";
	private String buttonImage = "";
	private String altField = "";
	private String altFormat = "";
	private String dateFormat = "";
	private String numberOfMonths = "[1,1]";

	private boolean mandatory = false;
	private boolean closeAtTop = true;
	private boolean hideIfNoPrevNext = false;
	private boolean gotoCurrent = false;
	private boolean navigationAsDateFormat = false;
	private boolean changeMonth = true;
	private boolean changeYear = true;
	private boolean changeFirstDay = true;
	private boolean highlightWeek = false;
	private boolean isRTL = false;
	private boolean showOtherMonths = false;
	private boolean showStatus = false;
	private boolean rangeSelect = false;
	private boolean showWeeks = false;
	private boolean buttonImageOnly = false;
	private int firstDay = 0;
	private int stepMonths = 1;
	private int duration = JQAnimation.ANIMATIONSPEED_DEFAULT;
	private String calculateWeek = "$.datepicker.iso8601Week";
	private String statusForDate = "this.dateStatus";

	private String beforeShowScript = "";
	private String beforeShowDayScript = "";
	private String onSelectScript = "";
	private String onChangeMonthYearScript = "";
	private String onCloseScript = "";
	
	/**
	 * Constructor
	 */
	public JQDatePickerOptions()
	{
		super();
		this.setDefaultHeader("datepicker");
	}

	/**
	 * Gets the clear text value
	 * 
	 * @return the clear text value
	 */
	public String getClearText()
	{
		return clearText;
	}

	/**
	 * Sets the clear text option value
	 * 
	 * @param clearText
	 *            datepicker clearText
	 */
	public void setClearText(String clearText)
	{
		this.clearText = clearText;
		this.options.put("clearText", "clearText:'" + clearText + "'");
	}

	/**
	 * Gets the close text value
	 * 
	 * @return the close text value
	 */
	public String getCloseText()
	{
		return closeText;
	}

	/**
	 * Sets the close text option value
	 * 
	 * @param closeText
	 *            datepicker closeText
	 */
	public void setCloseText(String closeText)
	{
		this.closeText = closeText;
		this.options.put("closeText", "closeText:'" + closeText + "'");
	}

	/**
	 * Gets the previous text value
	 * 
	 * @return the previous text value
	 */
	public String getPrevText()
	{
		return prevText;
	}

	/**
	 * Sets the previous text option value
	 * 
	 * @param prevText
	 *            datepicker prevText
	 */
	public void setPrevText(String prevText)
	{
		this.prevText = prevText;
		this.options.put("prevText", "prevText:'" + prevText + "'");
	}

	/**
	 * Gets the next text value
	 * 
	 * @return the next text value
	 */
	public String getNextText()
	{
		return nextText;
	}

	/**
	 * Sets the next text option value
	 * 
	 * @param nextText
	 *            datepicker nextText
	 */
	public void setNextText(String nextText)
	{
		this.nextText = nextText;
		this.options.put("nextText", "nextText:'" + nextText + "'");
	}

	/**
	 * Gets the current text value
	 * 
	 * @return the current text value
	 */
	public String getCurrentText()
	{
		return currentText;
	}

	/**
	 * Sets the current text option value
	 * 
	 * @param currentText
	 *            datepicker currentText
	 */
	public void setCurrentText(String currentText)
	{
		this.currentText = currentText;
		this.options.put("currentText", "currentText:'" + currentText + "'");
	}

	/**
	 * Gets the clear status value
	 * 
	 * @return the clear status value
	 */
	public String getClearStatus()
	{
		return clearStatus;
	}

	/**
	 * Sets the clear status option value
	 * 
	 * @param clearStatus
	 *            datepicker clearStatus
	 */
	public void setClearStatus(String clearStatus)
	{
		this.clearStatus = clearStatus;
		this.options.put("clearStatus", "clearStatus:'" + clearStatus + "'");
	}

	/**
	 * Gets the close status value
	 * 
	 * @return the close status value
	 */
	public String getCloseStatus()
	{
		return closeStatus;
	}

	/**
	 * Sets the close status option value
	 * 
	 * @param closeStatus
	 *            datepicker closeStatus
	 */
	public void setCloseStatus(String closeStatus)
	{
		this.closeStatus = closeStatus;
		this.options.put("closeStatus", "closeStatus:'" + closeStatus + "'");
	}

	/**
	 * Gets the previous status value
	 * 
	 * @return the previous status value
	 */
	public String getPrevStatus()
	{
		return prevStatus;
	}

	/**
	 * Sets the previous status option value
	 * 
	 * @param prevStatus
	 *            datepicker prevStatus
	 */
	public void setPrevStatus(String prevStatus)
	{
		this.prevStatus = prevStatus;
		this.options.put("prevStatus", "prevStatus:'" + prevStatus + "'");
	}

	/**
	 * Gets the next status value
	 * 
	 * @return the next status value
	 */
	public String getNextStatus()
	{
		return nextStatus;
	}

	/**
	 * Sets the next status option value
	 * 
	 * @param nextStatus
	 *            datepicker nextStatus
	 */
	public void setNextStatus(String nextStatus)
	{
		this.nextStatus = nextStatus;
		this.options.put("nextStatus", "nextStatus:'" + nextStatus + "'");
	}

	/**
	 * Gets the current status value
	 * 
	 * @return the current status value
	 */
	public String getCurrentStatus()
	{
		return currentStatus;
	}

	/**
	 * Sets the current status option value
	 * 
	 * @param currentStatus
	 *            datepicker currentStatus
	 */
	public void setCurrentStatus(String currentStatus)
	{
		this.currentStatus = currentStatus;
		this.options.put("currentStatus", "currentStatus:'" + currentStatus + "'");
	}

	/**
	 * Gets the month status value
	 * 
	 * @return the month status value
	 */
	public String getMonthStatus()
	{
		return monthStatus;
	}

	/**
	 * Sets the month status option value
	 * 
	 * @param monthStatus
	 *            datepicker monthStatus
	 */
	public void setMonthStatus(String monthStatus)
	{
		this.monthStatus = monthStatus;
		this.options.put("monthStatus", "monthStatus:'" + monthStatus + "'");
	}

	/**
	 * Gets the year status value
	 * 
	 * @return the year status value
	 */
	public String getYearStatus()
	{
		return yearStatus;
	}

	/**
	 * Sets the year status option value
	 * 
	 * @param yearStatus
	 *            datepicker yearStatus
	 */
	public void setYearStatus(String yearStatus)
	{
		this.yearStatus = yearStatus;
		this.options.put("yearStatus", "yearStatus:'" + yearStatus + "'");
	}

	/**
	 * Gets the week status value
	 * 
	 * @return the week status value
	 */
	public String getWeekStatus()
	{
		return weekStatus;
	}

	/**
	 * Sets the week status option value
	 * 
	 * @param weekStatus
	 *            datepicker weekStatus
	 */
	public void setWeekStatus(String weekStatus)
	{
		this.weekStatus = weekStatus;
		this.options.put("weekStatus", "weekStatus:'" + weekStatus + "'");
	}

	/**
	 * Gets the day status value
	 * 
	 * @return the day status value
	 */
	public String getDayStatus()
	{
		return dayStatus;
	}

	/**
	 * Sets the day status option value
	 * 
	 * @param dayStatus
	 *            datepicker dayStatus
	 */
	public void setDayStatus(String dayStatus)
	{
		this.dayStatus = dayStatus;
		this.options.put("dayStatus", "dayStatus:'" + dayStatus + "'");
	}

	/**
	 * Gets the init status value
	 * 
	 * @return the init status value
	 */
	public String getInitStatus()
	{
		return initStatus;
	}

	/**
	 * Sets the init status option value
	 * 
	 * @param initStatus
	 *            datepicker initStatus
	 */
	public void setInitStatus(String initStatus)
	{
		this.initStatus = initStatus;
		this.options.put("initStatus", "initStatus:'" + initStatus + "'");
	}

	/**
	 * Gets the date status value
	 * 
	 * @return the date status value
	 */
	public String getDateStatus()
	{
		return dateStatus;
	}

	/**
	 * Sets the date status option value
	 * 
	 * @param dateStatus
	 *            datepicker dateStatus
	 */
	public void setDateStatus(String dateStatus)
	{
		this.dateStatus = dateStatus;
		this.options.put("dateStatus", "dateStatus:'" + dateStatus + "'");
	}

	/**
	 * Gets the day names value
	 * 
	 * @return the day names value
	 */
	public String getDayNames()
	{
		return dayNames;
	}

	/**
	 * Sets the day names option value
	 * 
	 * @param dayNames
	 *            datepicker dayNames
	 */
	public void setDayNames(String dayNames)
	{
		this.dayNames = dayNames;
		this.options.put("dayNames", "dayNames:" + dayNames);
	}

	/**
	 * Gets the short day names value
	 * 
	 * @return the short day names value
	 */
	public String getDayNamesShort()
	{
		return dayNamesShort;
	}

	/**
	 * Sets the short day names option value
	 * 
	 * @param dayNamesShort
	 *            datepicker dayNamesShort
	 */
	public void setDayNamesShort(String dayNamesShort)
	{
		this.dayNamesShort = dayNamesShort;
		this.options.put("dayNamesShort", "dayNamesShort:" + dayNamesShort);
	}

	/**
	 * Gets the min day names value
	 * 
	 * @return the min day names value
	 */
	public String getDayNamesMin()
	{
		return dayNamesMin;
	}

	/**
	 * Sets the min day names option value
	 * 
	 * @param dayNamesMin
	 *            datepicker dayNamesmin
	 */
	public void setDayNamesMin(String dayNamesMin)
	{
		this.dayNamesMin = dayNamesMin;
		this.options.put("dayNamesmin", "dayNamesmin:" + dayNamesMin);
	}

	/**
	 * Gets the month names value
	 * 
	 * @return the month names value
	 */
	public String getMonthNames()
	{
		return monthNames;
	}

	/**
	 * Sets the month names option value
	 * 
	 * @param monthNames
	 *            datepicker monthNames
	 */
	public void setMonthNames(String monthNames)
	{
		this.monthNames = monthNames;
		this.options.put("monthNames", "monthNames:" + monthNames);
	}

	/**
	 * Gets the short month names value
	 * 
	 * @return the short month names value
	 */
	public String getMonthNamesShort()
	{
		return monthNamesShort;
	}

	/**
	 * Sets the short month names option value
	 * 
	 * @param monthNamesShort
	 *            datepicker monthNamesShort
	 */
	public void setMonthNamesShort(String monthNamesShort)
	{
		this.monthNamesShort = monthNamesShort;
		this.options.put("monthNamesShort", "monthNamesShort:" + monthNamesShort);
	}

	/**
	 * Gets the year range value
	 * 
	 * @return the year range value
	 */
	public String getYearRange()
	{
		return yearRange;
	}

	/**
	 * Sets the year range option value
	 * 
	 * @param yearRange
	 *            datepicker yearRange
	 */
	public void setYearRange(String yearRange)
	{
		this.yearRange = yearRange;
		this.options.put("yearRange", "yearRange:'" + yearRange + "'");
	}

	/**
	 * Gets the week header value
	 * 
	 * @return the week header value
	 */
	public String getWeekHeader()
	{
		return weekHeader;
	}

	/**
	 * Sets the week header option value
	 * 
	 * @param weekHeader
	 *            datepicker weekHeader
	 */
	public void setWeekHeader(String weekHeader)
	{
		this.weekHeader = weekHeader;
		this.options.put("weekHeader", "weekHeader:'" + weekHeader + "'");
	}

	/**
	 * Gets the range separator value
	 * 
	 * @return the range separator value
	 */
	public String getRangeSeparator()
	{
		return rangeSeparator;
	}

	/**
	 * Sets the range separator option value
	 * 
	 * @param rangeSeparator
	 *            datepicker rangeSeparator
	 */
	public void setRangeSeparator(String rangeSeparator)
	{
		this.rangeSeparator = rangeSeparator;
		this.options.put("rangeSeparator", "rangeSeparator:'" + rangeSeparator + "'");
	}

	/**
	 * Gets the default date value
	 * 
	 * @return the default date value
	 */
	public String getDefaultDate()
	{
		return defaultDate;
	}

	/**
	 * Sets the default date option value
	 * 
	 * @param defaultDate
	 *            datepicker defaultDate
	 */
	public void setDefaultDate(String defaultDate)
	{
		this.defaultDate = defaultDate;
		this.options.put("defaultDate", "defaultDate:'" + defaultDate + "'");
	}

	/**
	 * Gets the min date value
	 * 
	 * @return the min date value
	 */
	public String getMinDate()
	{
		return minDate;
	}

	/**
	 * Sets the min date option value
	 * 
	 * @param minDate
	 *            datepicker minDate
	 */
	public void setMinDate(String minDate)
	{
		this.minDate = minDate;
		this.options.put("minDate", "minDate:'" + minDate + "'");
	}

	/**
	 * Gets the max date value
	 * 
	 * @return the max date value
	 */
	public String getMaxDate()
	{
		return maxDate;
	}

	/**
	 * Sets the max date option value
	 * 
	 * @param maxDate
	 *            datepicker maxDate
	 */
	public void setMaxDate(String maxDate)
	{
		this.maxDate = maxDate;
		this.options.put("maxDate", "maxDate:'" + maxDate + "'");
	}

	/**
	 * Gets the short year cutoff value
	 * 
	 * @return the short year cutoff value
	 */
	public String getShortYearCutoff()
	{
		return shortYearCutoff;
	}

	/**
	 * Sets the short year cutoff option value
	 * 
	 * @param shortYearCutoff
	 *            datepicker shortYearCutoff
	 */
	public void setShortYearCutoff(String shortYearCutoff)
	{
		this.shortYearCutoff = shortYearCutoff;
		this.options.put("shortYearCutoff", "shortYearCutoff:'" + shortYearCutoff + "'");
	}

	/**
	 * Gets the append text value
	 * 
	 * @return the append text value
	 */
	public String getAppendText()
	{
		return appendText;
	}

	/**
	 * Sets the append text option value
	 * 
	 * @param appendText
	 *            datepicker appendText
	 */
	public void setAppendText(String appendText)
	{
		this.appendText = appendText;
		this.options.put("appendText", "appendText:'" + appendText + "'");
	}

	/**
	 * Gets the show on value
	 * 
	 * @return the show on value
	 */
	public String getShowOn()
	{
		return showOn;
	}

	/**
	 * Sets the show on option value
	 * 
	 * @param showOn
	 *            datepicker showOn
	 */
	public void setShowOn(String showOn)
	{
		this.showOn = showOn;
		this.options.put("showOn", "showOn:'" + showOn + "'");
	}

	/**
	 * Gets the show anim value
	 * 
	 * @return the show anim value
	 */
	public String getShowAnim()
	{
		return showAnim;
	}

	/**
	 * Sets the show animation option value
	 * 
	 * @param showAnim
	 *            datepicker showAnim
	 */
	public void setShowAnim(String showAnim)
	{
		this.showAnim = showAnim;
		this.options.put("showAnim", "showAnim:'" + showAnim + "'");
	}

	/**
	 * Gets the show animation's options
	 * 
	 * @return the show animation's options
	 */
	public JQPluginOptions getShowOptions()
	{
		return showOptions;
	}

	/**
	 * Sets the show animation settings
	 * 
	 * @param showOptions
	 *            datepicker showOptions
	 */
	public void setShowOptions(JQPluginOptions showOptions)
	{
		this.showOptions = showOptions;
		this.options.put("showOptions", "showOptions:" + showOptions.getDefaultString());
	}

	/**
	 * Gets the button text value
	 * 
	 * @return the button text value
	 */
	public String getButtonText()
	{
		return buttonText;
	}

	/**
	 * Sets the button text option value
	 * 
	 * @param buttonText
	 *            datepicker buttonText
	 */
	public void setButtonText(String buttonText)
	{
		this.buttonText = buttonText;
		this.options.put("buttonText", "buttonText:'" + buttonText + "'");
	}

	/**
	 * Gets the button image value
	 * 
	 * @return the button image value
	 */
	public String getButtonImage()
	{
		return buttonImage;
	}

	/**
	 * Sets the button image option value
	 * 
	 * @param buttonImage
	 *            datepicker buttonImage
	 */
	public void setButtonImage(String buttonImage)
	{
		this.buttonImage = buttonImage;
		this.options.put("buttonImage", "buttonImage:'" + buttonImage + "'");
	}

	/**
	 * Gets the alt field value
	 * 
	 * @return the alt field value
	 */
	public String getAltField()
	{
		return altField;
	}

	/**
	 * Sets the alt field option value
	 * 
	 * @param altField
	 *            datepicker altField
	 */
	public void setAltField(String altField)
	{
		this.altField = altField;
		this.options.put("altField", "altField:'" + altField + "'");
	}

	/**
	 * Gets the alt format value
	 * 
	 * @return the alt format value
	 */
	public String getAltFormat()
	{
		return altFormat;
	}

	/**
	 * Sets the alt format option value
	 * 
	 * @param altFormat
	 *            datepicker buttonImage
	 */
	public void setAltFormat(String altFormat)
	{
		this.altFormat = altFormat;
		this.options.put("altFormat", "altFormat:'" + altFormat + "'");
	}

	/**
	 * Gets the date format value
	 * 
	 * @return the date format value
	 */
	public String getDateFormat()
	{
		return dateFormat;
	}

	/**
	 * Sets the date format option value
	 * 
	 * @param dateFormat
	 *            datepicker date format
	 */
	public void setDateFormat(String dateFormat)
	{
		this.dateFormat = dateFormat;
		this.options.put("dateFormat", "dateFormat:'" + dateFormat + "'");
	}

	/**
	 * Gets the number of months
	 * 
	 * @return the number of months
	 */
	public String getNumberOfMonths()
	{
		return numberOfMonths;
	}

	/**
	 * Sets the number of month option value
	 * 
	 * @param numberOfMonths
	 *            datepicker month number
	 */
	public void setNumberOfMonths(String numberOfMonths)
	{
		this.numberOfMonths = numberOfMonths;
		this.options.put("numberOfMonths", "numberOfMonths:'" + numberOfMonths + "'");
	}

	/**
	 * Gets the mandatory value
	 * 
	 * @return the mandatory value
	 */
	public boolean isMandatory()
	{
		return mandatory;
	}

	/**
	 * Sets the mandatory option value
	 * 
	 * @param mandatory
	 *            datepicker mandatory
	 */
	public void setMandatory(boolean mandatory)
	{
		this.mandatory = mandatory;
		this.options.put("mandatory", "mandatory:" + mandatory);
	}

	/**
	 * Gets the close at top value
	 * 
	 * @return the close at top value
	 */
	public boolean isCloseAtTop()
	{
		return closeAtTop;
	}

	/**
	 * Sets the close at top option value
	 * 
	 * @param closeAtTop
	 *            datepicker close At Top
	 */
	public void setCloseAtTop(boolean closeAtTop)
	{
		this.closeAtTop = closeAtTop;
		this.options.put("closeAtTop", "closeAtTop:" + closeAtTop);
	}

	/**
	 * Gets the hide if not previous text value
	 * 
	 * @return the hide if not previous text value
	 */
	public boolean isHideIfNoPrevNext()
	{
		return hideIfNoPrevNext;
	}

	/**
	 * Sets the hideIfNoPrevNext option value
	 * 
	 * @param hideIfNoPrevNext
	 *            datepicker hideIfNoPrevNext
	 */
	public void setHideIfNoPrevNext(boolean hideIfNoPrevNext)
	{
		this.hideIfNoPrevNext = hideIfNoPrevNext;
		this.options.put("hideIfNoPrevNext", "hideIfNoPrevNext:" + hideIfNoPrevNext);
	}

	/**
	 * Gets the goto current value
	 * 
	 * @return the goto current value
	 */
	public boolean isGotoCurrent()
	{
		return gotoCurrent;
	}

	/**
	 * Sets the gotoCurrent option value
	 * 
	 * @param gotoCurrent
	 *            datepicker gotoCurrent
	 */
	public void setGotoCurrent(boolean gotoCurrent)
	{
		this.gotoCurrent = gotoCurrent;
		this.options.put("gotoCurrent", "gotoCurrent:" + gotoCurrent);
	}

	/**
	 * Gets the navigation as date format value
	 * 
	 * @return the navigation as date format value
	 */
	public boolean isNavigationAsDateFormat()
	{
		return navigationAsDateFormat;
	}

	/**
	 * Sets the navigation as date format option value
	 * 
	 * @param navigationAsDateFormat
	 *            datepicker navigationAsDateFormat
	 */
	public void setNavigationAsDateFormat(boolean navigationAsDateFormat)
	{
		this.navigationAsDateFormat = navigationAsDateFormat;
		this.options.put("navigationAsDateFormat", "navigationAsDateFormat:" + navigationAsDateFormat);
	}

	/**
	 * Gets the change month value
	 * 
	 * @return the change month value
	 */
	public boolean isChangeMonth()
	{
		return changeMonth;
	}

	/**
	 * Sets the change month option value
	 * 
	 * @param changeMonth
	 *            datepicker changeMonth
	 */
	public void setChangeMonth(boolean changeMonth)
	{
		this.changeMonth = changeMonth;
		this.options.put("changeMonth", "changeMonth:" + changeMonth);
	}

	/**
	 * Gets the change year value
	 * 
	 * @return the change year value
	 */
	public boolean isChangeYear()
	{
		return changeYear;
	}

	/**
	 * Sets the change year option value
	 * 
	 * @param changeYear
	 *            datepicker changeYear
	 */
	public void setChangeYear(boolean changeYear)
	{
		this.changeYear = changeYear;
		this.options.put("changeYear", "changeYear:" + changeYear);
	}

	/**
	 * Gets the change first year value
	 * 
	 * @return the change first year value
	 */
	public boolean isChangeFirstDay()
	{
		return changeFirstDay;
	}

	/**
	 * Sets the change first day option value
	 * 
	 * @param changeFirstDay
	 *            datepicker changeFirstDay
	 */
	public void setChangeFirstDay(boolean changeFirstDay)
	{
		this.changeFirstDay = changeFirstDay;
		this.options.put("changeFirstDay", "changeFirstDay:" + changeFirstDay);
	}

	/**
	 * Gets the highlight week value
	 * 
	 * @return the highlight week value
	 */
	public boolean isHighlightWeek()
	{
		return highlightWeek;
	}

	/**
	 * Sets the highlight week option value
	 * 
	 * @param highlightWeek
	 *            datepicker highlightWeek
	 */
	public void setHighlightWeek(boolean highlightWeek)
	{
		this.highlightWeek = highlightWeek;
		this.options.put("highlightWeek", "highlightWeek:" + highlightWeek);
	}

	/**
	 * Gets the rtl value
	 * 
	 * @return the rtl value
	 */
	public boolean isRTL()
	{
		return isRTL;
	}

	/**
	 * Sets the RTL option value
	 * 
	 * @param isRTL
	 *            datepicker RTL
	 */
	public void setRTL(boolean isRTL)
	{
		this.isRTL = isRTL;
		this.options.put("isRTL", "isRTL:" + isRTL);
	}

	/**
	 * Gets the show other months value
	 * 
	 * @return the show other months value
	 */
	public boolean isShowOtherMonths()
	{
		return showOtherMonths;
	}

	/**
	 * Sets the show other month option value
	 * 
	 * @param showOtherMonths
	 *            datepicker showOtherMonths
	 */
	public void setShowOtherMonths(boolean showOtherMonths)
	{
		this.showOtherMonths = showOtherMonths;
		this.options.put("showOtherMonths", "showOtherMonths:" + showOtherMonths);
	}

	/**
	 * Gets the show status value
	 * 
	 * @return the show status value
	 */
	public boolean isShowStatus()
	{
		return showStatus;
	}

	/**
	 * Sets the show status option value
	 * 
	 * @param showStatus
	 *            datepicker showStatus
	 */
	public void setShowStatus(boolean showStatus)
	{
		this.showStatus = showStatus;
		this.options.put("showStatus", "showStatus:" + showStatus);
	}

	/**
	 * Gets the range select value
	 * 
	 * @return the range select value
	 */
	public boolean isRangeSelect()
	{
		return rangeSelect;
	}

	/**
	 * Sets the range select option value
	 * 
	 * @param rangeSelect
	 *            datepicker rangeSelect
	 */
	public void setRangeSelect(boolean rangeSelect)
	{
		this.rangeSelect = rangeSelect;
		this.options.put("rangeSelect", "rangeSelect:" + rangeSelect);
	}

	/**
	 * Gets the show weeks value
	 * 
	 * @return the show weeks value
	 */
	public boolean isShowWeeks()
	{
		return showWeeks;
	}

	/**
	 * Sets the show weeks option value
	 * 
	 * @param showWeeks
	 *            datepicker showWeeks
	 */
	public void setShowWeeks(boolean showWeeks)
	{
		this.showWeeks = showWeeks;
		this.options.put("showWeeks", "showWeeks:" + showWeeks);
	}

	/**
	 * Gets the button image only value
	 * 
	 * @return the button image only value
	 */
	public boolean isButtonImageOnly()
	{
		return buttonImageOnly;
	}

	/**
	 * Sets the button image only option value
	 * 
	 * @param buttonImageOnly
	 *            datepicker buttonImageOnly
	 */
	public void setButtonImageOnly(boolean buttonImageOnly)
	{
		this.buttonImageOnly = buttonImageOnly;
		this.options.put("buttonImageOnly", "buttonImageOnly:" + buttonImageOnly);
	}

	/**
	 * Gets the first day value
	 * 
	 * @return the first day value
	 */
	public int getFirstDay()
	{
		return firstDay;
	}

	/**
	 * Sets the first day option value
	 * 
	 * @param firstDay
	 *            datepicker firstDay
	 */
	public void setFirstDay(int firstDay)
	{
		this.firstDay = firstDay;
		this.options.put("firstDay", "firstDay:" + firstDay);
	}

	/**
	 * Gets the step months value
	 * 
	 * @return the step months value
	 */
	public int getStepMonths()
	{
		return stepMonths;
	}

	/**
	 * Sets the step months option value
	 * 
	 * @param stepMonths
	 *            datepicker stepMonths
	 */
	public void setStepMonths(int stepMonths)
	{
		this.stepMonths = stepMonths;
		this.options.put("stepMonths", "stepMonths:" + stepMonths);
	}

	/**
	 * Gets the duration value
	 * 
	 * @return the duration value
	 */
	public int getDuration()
	{
		return duration;
	}

	/**
	 * Sets the duration option value
	 * 
	 * @param duration
	 *            datepicker duration
	 */
	public void setDuration(int duration)
	{
		this.duration = duration;
		this.options.put("duration", "duration:" + duration);
	}

	/**
	 * Gets the calculate week value
	 * 
	 * @return the calculate week value
	 */
	public String getCalculateWeek()
	{
		return calculateWeek;
	}

	/**
	 * Sets the calculateWeek option value
	 * 
	 * @param calculateWeek
	 *            datepicker calculateWeek
	 */
	public void setCalculateWeek(String calculateWeek)
	{
		this.calculateWeek = calculateWeek;
		this.options.put("calculateWeek", "calculateWeek:'" + calculateWeek + "'");
	}

	/**
	 * Gets the status for date value
	 * 
	 * @return the status for date value
	 */
	public String getStatusForDate()
	{
		return statusForDate;
	}

	/**
	 * Sets the status for date option value
	 * 
	 * @param statusForDate
	 *            datepicker statusForDate
	 */
	public void setStatusForDate(String statusForDate)
	{
		this.statusForDate = statusForDate;
		this.options.put("statusForDate", "statusForDate:'" + statusForDate + "'");
	}

	/**
	 * Gets the beforeShow script value
	 * 
	 * @return the beforeShow function
	 */
	public String getBeforeShowScript()
	{
		return beforeShowScript;
	}

	/**
	 * Sets the beforeShow function
	 * 
	 * @param beforeShowScript
	 *            droppable beforeShow function
	 */
	public void setBeforeShowScript(String beforeShowScript)
	{
		this.beforeShowScript = beforeShowScript;
		this.options.put("beforeShow", "beforeShow:function(input){" + beforeShowScript + "}");
	}

	/**
	 * Gets the beforeShowDay script value
	 * 
	 * @return the beforeShowDay function
	 */
	public String getBeforeShowDayScript()
	{
		return beforeShowDayScript;
	}

	/**
	 * Sets the beforeShowDay function
	 * 
	 * @param beforeShowDayScript
	 *            droppable beforeShowDay function
	 */
	public void setBeforeShowDayScript(String beforeShowDayScript)
	{
		this.beforeShowDayScript = beforeShowDayScript;
		this.options.put("beforeShowDay", "beforeShowDay:function(date){" + beforeShowDayScript + "}");
	}

	/**
	 * Gets the onSelect script value
	 * 
	 * @return the onSelect function
	 */
	public String getOnSelectScript()
	{
		return onSelectScript;
	}

	/**
	 * Sets the onSelect function
	 * 
	 * @param onSelectScript
	 *            droppable onSelect function
	 */
	public void setOnSelectScript(String onSelectScript)
	{
		this.onSelectScript = onSelectScript;
		this.options.put("onSelect", "onSelect:function(date){" + onSelectScript + "}");
	}

	/**
	 * Gets the OnChangeMonthYear script value
	 * 
	 * @return the OnChangeMonthYear function
	 */
	public String getOnChangeMonthYearScript()
	{
		return onChangeMonthYearScript;
	}

	/**
	 * Sets the onChangeMonthYear function
	 * 
	 * @param onChangeMonthYearScript
	 *            droppable onChangeMonthYear function
	 */
	public void setOnChangeMonthYearScript(String onChangeMonthYearScript)
	{
		this.onChangeMonthYearScript = onChangeMonthYearScript;
		this.options.put("onChangeMonthYear", "onChangeMonthYear:function(date){" + onChangeMonthYearScript + "}");
	}

	/**
	 * Gets the OnCloseScript script value
	 * 
	 * @return the OnCloseScript function
	 */
	public String getOnCloseScript()
	{
		return onCloseScript;
	}

	/**
	 * Sets the onClose function
	 * 
	 * @param onCloseScript
	 *            droppable onClose function
	 */
	public void setOnCloseScript(String onCloseScript)
	{
		this.onCloseScript = onCloseScript;
		this.options.put("onClose", "onClose:function(date){" + onCloseScript + "}");
	}
	
	@Override
	protected Object clone() throws CloneNotSupportedException
	{
		JQDatePickerOptions clone = (JQDatePickerOptions)super.clone();
		return clone;
	}
}
